/*  fonts */
@font-face {
  font-family: nav-arrow;
  src: url(fonts/nav-arrow.otf);
}
@font-face {
  font-family: NotoSansCHI;
  src: url(fonts/NotoSansCJKtc-Regular.otf);
}
@font-face {
  font-family: NotoSansJP;
  src: url(fonts/NotoSansCJKjp-Regular.otf);
}

@font-face {
  font-family: Comfortaa-Bold;
  src: url(fonts/Comfortaa-Bold.ttf);
}
@font-face {
  font-family: Nunito-Black;
  src: url(fonts/Nunito-Black.ttf);
}
@font-face {
  font-family: Nunito-Bold;
  src: url(fonts/Nunito-Bold.ttf);
}
@font-face {
  font-family: Nunito-Regular;
  src: url(fonts/Nunito-Regular.ttf);
}
@font-face {
  font-family: Nunito-Light;
  src: url(fonts/Nunito-Light.ttf);
}

body {
  background-color: white;
  font-family: nav-arrow, Nunito-regular, Arial, NotoSansCHI, NotoSansJP, sans-serif;
  margin: 0;
}
body button {font-family: nav-arrow, Nunito-regular, Arial, NotoSansCHI, NotoSansJP, sans-serif;}
h1, h2, h3 {font-family: Comfortaa-Bold, Arial, NotoSansCHI, NotoSansJP, sans-serif;}
h4, h5, h6 {font-family: Nunito-Black, Arial, NotoSansCHI, NotoSansJP, sans-serif;}
b {font-family: Nunito-Bold, Arial, NotoSansCHI, NotoSansJP, sans-serif;}

:root {
  --entrycontent-innerWidth: 70%;
  --Radius: 30px;
}

img {
  -webkit-user-drag: none; /* Chrome, Safari, Edge */
}



.container{
  width: 70%;
  max-width: 1500px;
  min-height: 100vh;
  margin: auto;
}
@media screen and (max-width: 700px) {
  .container{
    width: 100%;
  }
}
.show {
  display: block !important ; /*  MUST KEEP. Related to popup window function. */
}
a{color: inherit; text-decoration: none;
}



/* header */
#header{
  display: block;
  background-color: white;
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 1;
}
.header-block{
  display: flex;
  padding: 10px 0px;
  text-align: center;
  justify-content: center;
}
#headerlogo{
  display: block;
  width: fit-content;
  cursor: pointer;
}
#headerlogo img{
  width: 80px;
}

/* Contact */
#contactbtn{
	position: fixed;
	top: -20px;
	right: 0;
	width: 10%;
  min-width: 150px;
  aspect-ratio: 3 / 2;
  background-image: url("../structure/icon/Contact-me.svg");
  background-position: bottom;
  background-size: cover;
	z-index: 2;
	transition: 0.3s;
	transform-origin: top right;
  cursor: pointer;
}
#contactbtn:hover{
	transform: translate(0px, 20px);
}
#contactCard{
	display: none;
}
#contact-close-area{
  position: fixed;
  display: flex;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 3;
  background-color: rgba(0, 0, 0, 0.2);
  justify-content: center;
  align-items: center;
}
#contactCardBox{
  background-color: white;
  padding: 30px;
  width: 250px;
  border-radius: 20px;
  display: flex; justify-content: center; align-items: center; flex-direction: column; gap: 20px; text-align: left;
}
#contactInfo{
  display: flex; flex-direction: column; gap: 10px; 
}
.infoitem{
  display: flex; flex-direction: row; align-items: center;
}
.infoitem img{
  width: 20px; margin-right: 10px;
}
.infotext {position: relative; cursor: pointer;}
.feedback {
  position: absolute;
  top: 0;
  right: 0;
  color: #bbffcb;
  background-color: black;
  padding: 5px;
  opacity: 0;
  transition: opacity 0.3s ease;
  font-size: xx-small;
  z-index: 4;
  border-radius: 5px;
  font-weight: bold;
}
        
.feedback.show {
  opacity: 1;
}








/* filter side menu */
#side-menu {
  display: block;
  overflow: hidden;
  max-height: 1000px; /* set to content's max possible height */
  opacity: 1;
  transition: max-height 0.5s cubic-bezier(.5,0,.5,1), opacity 0.5s, transform 0.5s cubic-bezier(.68,-0.55,.27,1.55);
  transform-origin: bottom right;
}
#side-menu.closed {
  max-height: 0;
  transform: scale(0.2);
  opacity: 0;
  pointer-events: none;
  /* No display: none here! Will be set after animation via JS */
}



#side-menu-bg-bubble{
  background-color: #f0f0f0;
  border-radius: 50px;
}
#side-menu-bg-bubble-pointer-block{
  display: flex;
  justify-content: right;
}
#side-menu-bg-bubble-pointer{
  width: 50px;
  margin-right: 100px;
}
.side-menu-content {
  display: grid;
  grid-template-columns: 50% 50%;
  padding: 50px;
  gap: 20px;
  position: relative;
}
@media screen and (max-width: 1200px) {
  #side-menu{margin: 0px 20px;}
  .side-menu-content {grid-template-columns: 100%;}
}
#intro {
  font-family: Comfortaa-Bold;
  font-weight: 650;
  margin-bottom: 30px;
}
#side-menu-close{
  position: absolute;
  top: 30px;
  right: 30px;
  font-size: large;
  background-color: white;
  color: #b0b0b0;
  padding: 5px;
  text-align: center;
  width: 24px;
  aspect-ratio: 1/1;
  border-radius: 20px;
  font-family: Nunito-Black;
  cursor: pointer;
}


/* Show All and Category buttons */

#categorylist {
  display: block;
}
.categorysection{
  color: black;
  font-family: Comfortaa-Bold;
  font-size: large;
  display: inline-block;
  line-height: 2.5;
}
.categorybtn:not(.empty, .active):hover {
  background-color: white;
  color: #666;
}
.categorysection .active{
  background-color: black;
  color: white;
  font-weight: bold;
}
.categorybtn{
  text-align: left;
  border: none;
  outline: none;
  margin: 0px 5px;
  background-color: #d5d5d5;
  border-radius: 10px;
  line-height: 1;
  padding: 5px 10px;
  color: black;
  font-size: medium;
  cursor: pointer;
  display: inline-block;
}
.categorysection .empty{
  cursor: auto;
  opacity: 40%;
}










/* Tag Section */ 
#tagsection {
  display: block;
  color: black;
  font-family: Comfortaa-Bold;
  font-size: large;
  margin-top: 30px;
}
.tagsection button {
  font-family: Nunito-Regular;
  color: #4c4c4c;
  font-size: small;
  padding: 5px 8px;
  margin: 2px;
  text-decoration: none;
  display: inline;
  border: none;
  outline: none;
  background-color: #ffffff;
  cursor: pointer;
  border-radius: 10px;
}
.tagsection .active{
  background-color: black;
  color: white;
  font-family: Nunito-Bold;
}
.tagsection button:not(.empty):hover {background-color: #e0e0e0}
.tagsection button.active:hover {background-color: black;}

.tagsection .empty {
  cursor: auto;
  opacity: 40%;
}









.filterResult-container {
  margin-bottom: 50px;
}


/* Grid view */
.entry-container.grid {
  display: flex;
  flex-direction: column;
  gap: 50px;
}
.entry-grid.grid { /* entry outter grid style */
  display: block;
}

.entry.grid { /* entry inner grid style */
  outline: #ddd solid 1px;
  border-radius: var(--Radius);
}
@media screen and (max-width: 700px) {
  .entry.grid{
    margin: 0px 10px;
  }
}

/* entry grid content style */

.indexpage-projectInfoBox.grid{
  position: absolute;
  width: 30%;
  height: 100%;
  top: 0px;
  left: 10%;
  background-color: rgba(255, 255, 255, 0.85);
  color: black;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 50px;
}
.indexpage-thumbnail img{
  width: 100%;
  aspect-ratio: 2.5 / 1;
  object-fit: cover;
  display: block;
  object-fit: cover;
  border-radius: var(--Radius);
}






/* List view */

.entry-container.list {
  display: block;
  width: 75%;
  margin: 0px auto;
}
@media only screen and (max-width: 700px) {
  .entry-container.list{
    width: 100%;
  }
}
.entry-grid.list { /* entry outter grid style */
  display: block;
  margin: 12px 0px;
}
@media screen and (max-width: 700px){
  .entry-grid.list {margin: 12px 24px;}
}
.entry.list { /* entry inner grid style */
  background-color: #f1f1f1;
  color: black;
  display: grid;
  grid-template-columns: 10% 50% 40%;
  border: solid transparent 1px;
  border-top-right-radius: 15px;
  border-bottom-right-radius: 15px;
}
@media screen and (max-width: 650px){
  .entry.list {
    grid-template-columns: 15% 45% 40%;
  }
}
.entry.list:hover{transform: translateX(10px);border: solid #ccc 1px;}

/* entry list content style */

.indexpage-projectID.list {
  font-family: Nunito-Bold;
  font-size: xx-small;
  background-color: #aaa;
  color: white;
  padding: 6px;
  display: inline-block;
  text-align: center;
  margin: auto 0px;
  border-top-right-radius: 15px;
  border-bottom-right-radius: 15px;
}
.indexpage-title.list{
  font-family: Nunito-Bold;
  font-size:small; 
  font-weight: bold;
  text-align: left;
  margin: auto 30px;
  padding: 5px 0px;
}
@media screen and (max-width: 650px){
  .indexpage-title.list {
    margin: auto 25px;
  }
}
.indexpage-caption.list{
  display: inline;
  text-align: left;
  margin: auto 3px;
  font-size: x-small;
  color: #666;
  padding: 5px 0px;
}
.indexpage-category.list{
  display: inline;
  text-align: left;
  font-weight: bold;
}
.indexpage-tag.list{
  display: inline;
  text-align: left;
}











/* page button */

.page-btn-bar {
  display: block;
  width: 100%;
  padding-bottom: 8px;
  text-align:center;
}
.page-btn {
	text-align:center;
	width:auto;
	padding: 0px 5px;
	margin: auto 5px;
	display:inline-block;
	background-color: #ccc;
	color: black;
  font-family: Nunito-Bold;
	font-size: xx-small;
  border: 0;
  border-radius: 10px;
  cursor: pointer;
}
.page-btn.active {
  text-align:center;
	width:auto;
	padding:4px 8px;
	margin: auto 5px;
	display:inline-block;
	background-color: black;
  color: white;
	font-size: medium;
  border: 0;
  border-radius: 15px;
  cursor: default;
}
.page-btn:hover {
  background-color: #666;
  color: white; 
}
.page-btn.active:hover {
	background-color: black;
  color: white;
}


#entry-toolbar{
  display: flex;
  justify-content: right;
  gap: 5px;
  width: 100%;
  margin-bottom: 20px;
  text-align: right;
}

#ViewBtn{
  width: 80px;
  cursor: pointer;
}
@media only screen and (max-width: 700px) {
  #ViewBtn{
    margin-right: 20px;
  }
}
#ViewBtn:hover{
  opacity: 80%;
}

/* Filter Side-menu Button */
#filterbtn {
  background-color: black;
  font-family: Nunito-Bold;
  color: white;
  border-radius: 15px;
  padding: 5px 15px;
  cursor: pointer;
  display: flex;
  flex-direction: row;
  height: fit-content;
}
/* Side-menu button on hover & focus */
#filterbtn:hover, #filterbtn:focus {
  opacity: 80%;
}





footer {
  width: 100%;
  display: block;
  text-align: center;
  font-size: xx-small;
  padding: 20px 0px;
}

